/**
 * 协议
 * @return {[type]} [description]
 */
var url1=window.sessionStorage.getItem('url1');
var name=window.sessionStorage.getItem('username');
var protocol_name=window.sessionStorage.getItem('protocolName');
$.ajax({
    url:url1+'listFields',
    type:'POST',
    data:{'protocolName':protocol_name},
    dataType:'json',
    success:function (datas) {
        var holder=$('#holder_of_items');
        holder.html('');
		var per=datas.data;
		for(var i=0;i<per.length;i++){
			var one_item=$('<div></div>');
			one_item.addClass('one_item');
			var fieldName=$('<div></div>');
			fieldName.addClass('items');
			fieldName.attr('id','name');
			fieldName.html(per[i].fieldName);
			one_item.append(fieldName);
			var field_length=$('<div></div>');
			field_length.addClass('items');
			field_length.attr('id','length');
			field_length.html(per[i].length);
			one_item.append(field_length);
			var field_start=$('<div></div>');
			field_start.addClass('items');
			field_start.attr('id','start');
			field_start.html(per[i].start);
			one_item.append(field_start);
			holder.append(one_item);
		}
    }
});

